| Rank | StateName | Population |
|---|---|---|
| 1 | São Paulo | 46289333 |
| 2 | Minas Gerais | 21331292 |
| 3 | Rio de Janeiro | 17366189 |
| 4 | Bahia | 14930634 |
| 5 | Paraná | 11516840 |
| 6 | Rio Grande do Sul | 11422973 |
| 7 | Pernambuco | 9616621 |
| 8 | Ceará | 9187103 |
| 9 | Pará | 8690745 |
| 10 | Santa Catarina | 7279638 |
| 12 | Goiás | 7142070 |
| 11 | Maranhão | 7127460 |
| 13 | Amazonas | 4228381 |
| 14 | Espírito Santo | 4064052 |
| 15 | Paraíba | 4039277 |
| 16 | Rio Grande do Norte | 3534165 |
| 17 | Mato Grosso | 3526220 |
| 18 | Alagoas | 3351543 |
| 19 | Piauí | 3281480 |
| 20 | Distrito Federal | 3055149 |
| 21 | Mato Grosso do Sul | 2809394 |
| 22 | Sergipe | 2318822 |
| 23 | Rondônia | 1796460 |
| 24 | Tocantins | 1590248 |
| 25 | Acre | 894470 |
| 26 | Amapá | 861773 |
| 27 | Roraima | 631181 |
Dataset it was created based in Wikipedia Brazilian Population by State.
This board was created using flashdashboard and leaflet library.
Click in circles to see more details.
---
title: "Brazilian Population"
subtitle: "by Expedito Pinto de Paula Junior"
output:
flexdashboard::flex_dashboard:
orientation: columns
vertical_layout: fill
social: menu
source_code: embed
---
```{r setup, include=FALSE}
library(flexdashboard)
# Load DataSet
bpop <- read.csv("BrazilPopulation.csv", header = TRUE, sep = ";", dec = ",")
```
Column {data-width=650}
-----------------------------------------------------------------------
### Mapping using "leaflet"
```{r}
library(leaflet)
df <- data.frame(name = bpop$StateName,
pop = bpop$Population,
lat = bpop$Lat,
lng = bpop$Lon)
df %>%
leaflet() %>%
addTiles() %>%
addCircles(weight = 2, radius = sqrt(bpop$Population) * 50, popup =
paste("State: ",bpop$StateName," - ", bpop$State, "
",
"Population: ",bpop$Population, "
",
"Equivalent Country: ",bpop$Equivalent_Country,""), group="int")
```
Column {data-width=350}
-----------------------------------------------------------------------
### Total and Ranking
#### Total Population: **`r sum(bpop$Population)`**
```{r}
knitr::kable(bpop[c("Rank","StateName","Population")])
```
### General Info
#### **DataSet**
- Dataset it was created based in Wikipedia [Brazilian Population by State](https://pt.wikipedia.org/wiki/Lista_de_unidades_federativas_do_Brasil_por_popula%C3%A7%C3%A3o).
- This board was created using **flashdashboard** and **leaflet** library.
- Click in circles to see more details.
#### **Author**
- Designed by: **Expedito Pinto de Paula Junior**
- Course: **Developing Data Products**
- Date: **Nov, 16 2020**